Rollup of 16 pull requests#156166
Conversation
Co-authored-by: León Orell Valerian Liehr <me@fmease.dev>
These changes were made falsely assuming documentation links from `core` to `std` were not possible. Since it is possible, we can restore the documentation to its original form prior to the `core::io` move.
My benchmarking did not show any issue with using the safe method instead so I assume this isn't an issue any more. But let's do a perf run to be sure.
…nabled, not when `needs_crate_hash` is true. Exactly as the comment on the `crate_hash` field of `Linker` says, that field is only used when incremental compilation is enabled. `needs_crate_hash` returns true in some other cases too.
It's easy to confuse the functionality of `needs_crate_hash` with "is the crate_hash query needed" right now. The function returns whether we need to calculate the stable hash of various hir structs.
`trait_info_of` already returns `None` for unsized types, so allowing `T: ?Sized` is sound and lets callers in generic contexts use these functions without a separate `Sized` bound. For unsized `T`, the function always returns `None`.
…king as expected
So that commits under different names are still caught
Just gating `...` is insufficient because we make the types available everywhere, and you could still define and export functions that used va_arg for targets where we don't want to stably support it.
…y stable features
Especially those happening during normal resolving, where we are actually looking at current parent scopes
`Drop::drop(&mut f)` now correctly suggests `drop(f)` instead of the bare `drop` with no argument. Signed-off-by: Usman Akinyemi <usmanakinyemi202@gmail.com>
* Improve diagnostics for pinned reference patterns * Gate pin pattern suggestion on pin ergonomics * Document pin ergonomics suggestion gate * Remove unnecessary incomplete_features allow Co-authored-by: Redddy <midzy0228@gmail.com> * Remove redundant incomplete_features allow UI tests already allow incomplete_features by default, so the explicit allow is unnecessary. * Update ref-pat-suggestions stderr Bless line-number changes after removing the redundant incomplete_features allow. * Simplify pinned ref pattern suggestion gating * Fix formatting * More formatting fixes
…rk-Simulacrum [doc]: Revert `core::io::ErrorKind` doc changes ACP: rust-lang/libs-team#755 Tracking issue: rust-lang#154046 Related: rust-lang#154654 ## Description rust-lang#154654 changed the documentation for `ErrorKind` to remove links to `std` items. These changes were made falsely assuming documentation links from `core` to `std` were not possible. Since it is possible, we can restore the documentation to its original form prior to the `core::io` move. ## Notes * No AI tooling of any kind was used in the creation of this PR.
…ark-Simulacrum Remove unnecessary `get_unchecked` My benchmarking did not show any issue with using the safe method instead so I assume this isn't an issue any more. But let's do a perf run to be sure.
…ures, r=BoxyUwU docs(unstable-book): Document const generics features Relevant tracking issues: rust-lang#113521 rust-lang#132980 rust-lang#76560 rust-lang#151972 ## What Adds a high-level overview of 4 unstable features related to const generic exprs. ## Why While trying to learn about the current state of const generic exprs, I found it a bit too hard due to lack of documentation -- had to read through a bunch of tracking issues & look for PRs/examples in the repo just to understand what the feature is about. Moreover, given that there is a bunch of features with similarly-looking names, it was even more confusing. For that purpose, I also added cross-referencing across (directly or logically) related features. As a result, I decided to add some more context to the unstable book, so that new readers have an easier time than I had. ## Caveats I understand that the features are incomplete/experimental, so the docs are at risk of becoming stale, but the book entrypoint already has [a corresponding warning](https://doc.rust-lang.org/unstable-book/), so I guess it should be fine. Also, given that I did research myself, the examples provided might be not the best to showcase the feature -- happy to provide better examples, if you have suggestions. The examples provided are what "made the feature make sense" to me as an outsider, so there is a chance that they will be good for other external readers too, though. LLM use disclosue: an LLM was used for self-review only; research, coming up with examples, and writing is mine. Issues reported by LLM were fixed manually too. r? @BoxyUwU
…et-feature, r=RalfJung `rustc`: `target_features`: allow for `cfg`-only stable `target_features` This PR introduces a new stabilization level for `target_features`: `CfgOnlyStable`. The motivation is allowing the Rust compiler to expose `target_features` of targets so users can use `cfg(target_feature = "feature")` for conditional blocks depending on target features. However, `CfgOnlyStable` cannot be used for `#[target_feature(enable = "feature")]`, as this is still considered unstable. Accordingly, the compiler will still raise an error if these expressions are used on stable. This PR relates partially to rust-lang#150257. As discussed, for RISC-V targets, having the `"d"`, `"e"`, and `"f"` target features exposed will allow baremetal developers to adapt the code depending on the target's properties. r? @RalfJung
…-test, r=joshtriplett c-variadic: gate `va_arg` on `c_variadic_experimental_arch` tracking issue: rust-lang#44930 Just gating `...` is insufficient because we make the types available everywhere, and you could still define and export functions that used va_arg for targets where we don't want to stably support it. r? joshtriplett
…ted-types, r=petrochenkov Move tests associated types Hi, I have moved some ui tests I feel belong in the associated types folder
…ns, r=Kivooeo Improve `&pin` reference-pattern suggestions This fills in the `pin_ergonomics` FIXME in `borrow_pat_suggestion` by making the diagnostic prefix account for both `Pinnedness` and `Mutability`. Previously, the type-position suggestion path used ordinary reference spelling, which can spell `&` and `&mut` but cannot correctly spell pinned reference-pattern suggestions such as `&pin const` and `&pin mut`. This is a diagnostic-only change. It adds focused UI coverage for both pinned const and pinned mut reference-pattern suggestions.
|
@bors r+ rollup=never p=5 |
This comment has been minimized.
This comment has been minimized.
Rollup of 16 pull requests Successful merges: - #155848 ([doc]: Revert `core::io::ErrorKind` doc changes) - #155855 (Remove unnecessary `get_unchecked`) - #155543 (docs(unstable-book): Document const generics features) - #155962 (`rustc`: `target_features`: allow for `cfg`-only stable `target_features`) - #156043 (c-variadic: gate `va_arg` on `c_variadic_experimental_arch`) - #156082 (Move tests associated types) - #156087 (Improve `&pin` reference-pattern suggestions) - #156092 (Clean up `TyCtxt::needs_crate_hash` usage and rename it to `needs_hir_hash`.) - #156103 (Fix E0040 suggestion for explicit `Drop::drop` UFCS calls) - #156104 (Relax `T: Sized` bound on `try_as_dyn` / `try_as_dyn_mut`) - #156122 (Add a `doc_cfg` regression test to ensure foreign types impls are working as expected) - #156128 (.mailmap: prefer matching just based on commit emails) - #156135 (Remove most uses of def_id_to_node_id) - #156152 (Update books) - #156154 (tests: mark import UI tests as check-pass) - #156162 (Update `browser-ui-test` version to `0.23.5`)
|
💔 Test for cc54c7e failed: CI. Failed job:
|
|
The job Click to see the possible cause of the failure (guessed by this bot) |
|
@bors retry |
This comment has been minimized.
This comment has been minimized.
What is this?This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.Comparing 83adf7e (parent) -> 4feb722 (this PR) Test differencesShow 167 test diffsStage 1
Stage 2
(and 18 additional test diffs) Additionally, 49 doctest diffs were found. These are ignored, as they are noisy. Job group index
Test dashboardRun cargo run --manifest-path src/ci/citool/Cargo.toml -- \
test-dashboard 4feb7221f4d445120a5061b16ce7222adbfdf6f6 --output-dir test-dashboardAnd then open Job duration changes
How to interpret the job duration changes?Job durations can vary a lot, based on the actual runner instance |
|
📌 Perf builds for each rolled up PR:
previous master: 83adf7e080 In the case of a perf regression, run the following command for each PR you suspect might be the cause: |
|
Finished benchmarking commit (4feb722): comparison URL. Overall result: no relevant changes - no action needed@rustbot label: -perf-regression Instruction countThis perf run didn't have relevant results for this metric. Max RSS (memory usage)Results (primary -1.3%, secondary -0.5%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (secondary -0.3%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis perf run didn't have relevant results for this metric. Bootstrap: 495.736s -> 495.518s (-0.04%) |
Successful merges:
core::io::ErrorKinddoc changes #155848 ([doc]: Revertcore::io::ErrorKinddoc changes)get_unchecked#155855 (Remove unnecessaryget_unchecked)rustc:target_features: allow forcfg-only stabletarget_features#155962 (rustc:target_features: allow forcfg-only stabletarget_features)va_argonc_variadic_experimental_arch#156043 (c-variadic: gateva_argonc_variadic_experimental_arch)&pinreference-pattern suggestions #156087 (Improve&pinreference-pattern suggestions)TyCtxt::needs_crate_hashusage and rename it toneeds_hir_hash. #156092 (Clean upTyCtxt::needs_crate_hashusage and rename it toneeds_hir_hash.)Drop::dropUFCS calls #156103 (Fix E0040 suggestion for explicitDrop::dropUFCS calls)T: Sizedbound ontry_as_dyn/try_as_dyn_mut#156104 (RelaxT: Sizedbound ontry_as_dyn/try_as_dyn_mut)doc_cfgregression test to ensure foreign types impls are working as expected #156122 (Add adoc_cfgregression test to ensure foreign types impls are working as expected)browser-ui-testversion to0.23.5#156162 (Updatebrowser-ui-testversion to0.23.5)r? @ghost
Create a similar rollup